<template>
  <div>
    <div class="title-container">
      <div class="title-container__title">
        <div class="title-container__title__line"></div>
        <div class="title-container__title__text">{{ title }}</div>
      </div>
      <div class="title-container__right">
        <slot></slot>
      </div>
    </div>
  </div>
</template>

<script lang="ts" setup>
defineOptions({ name: 'Title' })
defineProps({
  title: {
    type: String,
    default: '',
  },
})
</script>

<style scoped lang="scss">
.title-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 32px;
  margin-bottom: 20px;
  .title-container__title {
    display: flex;
    align-items: center;
    gap: 6px;
    .title-container__title__line {
      width: 3px;
      height: 16px;
      background: #0966f0;
      border-radius: 6px;
    }
    .title-container__title__text {
      color: #333333;
      font-size: 16px;
      font-weight: 500;
    }
  }
}
</style>
